package com.wiseMen.weixin.user;

import javax.persistence.Table;
import javax.persistence.Transient;

import com.alibaba.fastjson.JSONObject;
import com.wiseMen.core.dao.BaseEntity;

@Table(name = "WX_USER")
public class WxUserEntity implements BaseEntity{

	private static final long serialVersionUID = 3600778605722518612L;
	
	private String id;//openId
	private String username;//用户名
	private String password;//密码
	private Integer state;//用户状态 0：正常 1：密码不正确 
	
	@Transient
	private String userid;
	@Transient
	private String acceptCode;
	@Transient
	private String belongorgType;
	@Transient
	private String colleges;
	@Transient
	private String email;
	@Transient
	private String flag;
	@Transient
	private String identification;
	@Transient
	private String ifAdministrator;
	@Transient
	private String ifDel;
	@Transient
	private String ifExpert;
	@Transient
	private String name;
	@Transient
	private String orgId;
	@Transient
	private String orgName;
	@Transient
	private String personId;
	@Transient
	private String phone;
	@Transient
	private String qq;
	@Transient
	private String realName;
	@Transient
	private String regSource;
	@Transient
	private String roleCode;//角色code
	@Transient
	private String score;
	
	public WxUserEntity(){}
	public WxUserEntity(JSONObject json){
		this.userid=json.getString("id");
		this.acceptCode=json.getString("acceptCode");
		this.belongorgType=json.getString("belongorgType");
		this.colleges=json.getString("colleges");
		this.email=json.getString("email");
		this.flag=json.getString("flag");
		this.identification=json.getString("identification");
		this.ifAdministrator=json.getString("ifAdministrator");
		this.ifDel=json.getString("ifDel");
		this.ifExpert=json.getString("ifExpert");
		this.name=json.getString("name");
		this.orgId=json.getString("orgId");
		this.orgName=json.getString("orgName");
		this.personId=json.getString("personId");
		this.phone=json.getString("phone");
		this.qq=json.getString("qq");
		this.realName=json.getString("realName");
		this.regSource=json.getString("regSource");
		this.score=json.getString("score");
		this.username=json.getString("username");
		this.roleCode=json.getString("roleCode");
	}
	
	public String getId() {
		return id;
	}
	public void setId(String id) {
		this.id = id;
	}
	public String getAcceptCode() {
		return acceptCode;
	}
	public void setAcceptCode(String acceptCode) {
		this.acceptCode = acceptCode;
	}
	public String getBelongorgType() {
		return belongorgType;
	}
	public void setBelongorgType(String belongorgType) {
		this.belongorgType = belongorgType;
	}
	public String getColleges() {
		return colleges;
	}
	public void setColleges(String colleges) {
		this.colleges = colleges;
	}
	public String getEmail() {
		return email;
	}
	public void setEmail(String email) {
		this.email = email;
	}
	public String getFlag() {
		return flag;
	}
	public void setFlag(String flag) {
		this.flag = flag;
	}
	public String getIdentification() {
		return identification;
	}
	public void setIdentification(String identification) {
		this.identification = identification;
	}
	public String getIfAdministrator() {
		return ifAdministrator;
	}
	public void setIfAdministrator(String ifAdministrator) {
		this.ifAdministrator = ifAdministrator;
	}
	public String getIfDel() {
		return ifDel;
	}
	public void setIfDel(String ifDel) {
		this.ifDel = ifDel;
	}
	public String getIfExpert() {
		return ifExpert;
	}
	public void setIfExpert(String ifExpert) {
		this.ifExpert = ifExpert;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public String getOrgId() {
		return orgId;
	}
	public void setOrgId(String orgId) {
		this.orgId = orgId;
	}
	public String getOrgName() {
		return orgName;
	}
	public void setOrgName(String orgName) {
		this.orgName = orgName;
	}
	public String getPersonId() {
		return personId;
	}
	public void setPersonId(String personId) {
		this.personId = personId;
	}
	public String getPhone() {
		return phone;
	}
	public void setPhone(String phone) {
		this.phone = phone;
	}
	public String getQq() {
		return qq;
	}
	public void setQq(String qq) {
		this.qq = qq;
	}
	public String getRealName() {
		return realName;
	}
	public void setRealName(String realName) {
		this.realName = realName;
	}
	public String getRegSource() {
		return regSource;
	}
	public void setRegSource(String regSource) {
		this.regSource = regSource;
	}
	public String getRoleCode() {
		return roleCode;
	}
	public void setRoleCode(String roleCode) {
		this.roleCode = roleCode;
	}
	public String getScore() {
		return score;
	}
	public void setScore(String score) {
		this.score = score;
	}
	public String getUsername() {
		return username;
	}
	public void setUsername(String username) {
		this.username = username;
	}
	public String getPassword() {
		return password;
	}
	public void setPassword(String password) {
		this.password = password;
	}
	public Integer getState() {
		return state;
	}
	public void setState(Integer state) {
		this.state = state;
	}
	public String getUserid() {
		return userid;
	}
	public void setUserid(String userid) {
		this.userid = userid;
	}
}
